const app= getApp();
Page({
  data: {
    active: 1,
    list:[],
    info:[],
    type:0
  },
  onLoad(){
    this.getvideo()
    this.getinfo()
  },
  getvideo(){
    app.get('video/list').then(res => {
      console.log(res)
      this.setData({
        list:res.data
      })
    })
  },
  getinfo(){
    app.get('info/list').then(res => {
      console.log(res)
      this.setData({
        info:res.data
      })
    })
  },
  onChange(event) {
    let type1 = event.detail.name;
    this.setData({
      type:type1
    });
  },
});